find largest and smallest number in an array example in Java